<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" 
    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml"
      xmlns:ui="http://java.sun.com/jsf/facelets"
      xmlns:h="http://java.sun.com/jsf/html"
      xmlns:f="http://java.sun.com/jsf/core"
      xmlns:p="http://primefaces.prime.com.tr/ui">

    <h:head>
        <title>Admin Ana Sayfa</title>
        <link href="../style.css" rel="stylesheet" type="text/css"></link>
       <div style="text-align: center;height:139px;background-color: #2D99FF"></div>

    </h:head>
    <h:body>
        
            <div id="wrapper">
                <div id="logo">

                </div>
                <div id="header">
                    <!-- 		<div id="menu">
                    
                            </div>    -->
                </div>
                <div class="page">
                    <div id="page-bgtop">

                        <div id="dummy"></div>
                        <p:panel id="panelsidebar" header="Pages Menu">
                            <ui:include src="MenuAdmin.xhtml"/>
                        </p:panel>

                        <!-- end #sidebar -->
<h:form prependId="false">
                        <div id="content">
                            <p:panel id="panel" header="İhale Ekleme Paneli">
                                <h:panelGrid columns="2">
                                    <h:outputText value="Ad*"/>
                                    <h:inputText value="#{adminBean.ihale.ad}" required="true" requiredMessage="İhale Adını alanı zorunlu alandır."/>
                                    <h:outputText value="Başlangıç Tarihi*"/>
                                    <p:calendar value="#{adminBean.ihale.baslamaTarihi}" pattern="dd/MM/yyyy" required="true" requiredMessage="İhale Başlama Tarihi zorunlu alandır." />
                                    <h:outputText value="Başlangıç Saati*"/>
                                    <p:inputMask mask="99:99" value="#{adminBean.ihale.baslangicSaati}" required="true" requiredMessage="İhale Başlama Saati zorunlu alandır." />
                                    <h:outputText value="Bitiş Tarihi*"/>
                                    <p:calendar value="#{adminBean.ihale.bitisTarihi}" pattern="dd/MM/yyyy" required="true" requiredMessage="İhale Bitiş Tarihi zorunlu alandır."/>
                                    <h:outputText value="Bitiş Saati*"/>
                                    <p:inputMask mask="99:99" value="#{adminBean.ihale.bitisSaati}" required="true" requiredMessage="İhale Bitiş Tarihi zorunlu alandır." />
                                    <h:outputText value="Satın Almacı Seçiniz*"/>
                                    <h:selectOneMenu id="suburbs" value="#{adminBean.satinAlmaciId}"  >
                                        <f:selectItem itemLabel="Satın Almacı Seçiniz" itemValue="null" />
                                        <f:selectItems value="#{adminBean.satinAlmacilar}" />
                                    </h:selectOneMenu>
                                    <h:outputText value="Açıklama"/>

                                    <h:inputTextarea value="#{adminBean.ihale.aciklama}" id="bolge" />
                                    <p:resizable for="bolge" minWidth="250" minHeight="100" maxWidth="350" maxHeight="500"/>
                                    <h:outputText value="Belge"/>
                                    <p:fileUpload fileUploadListener="#{adminBean.handleFileUpload}"   
                                                  allowTypes="*.pdf;*.xls;*.doc;*.docx;" description="Documents"/> 
                                    <p:commandButton value="Ekle" ajax="false" update="panel" action="#{adminBean.ekleIhale()}"/>



                                </h:panelGrid>
                                <p:messages/>
                               

                            </p:panel> 

                        </div>
                        <!-- end #content -->
</h:form>
                        <div style="clear: both;">&nbsp;</div>
                    </div>

                    <!-- end #page -->

                </div>
                <div id="footer-bgcontent">
                    <div id="footer" align="center">
                        <p>İHALE YÖNETİM SİSTEMİ - 2011</p>
                    </div>
                </div>
                <!-- end #footer -->
            </div>

        
    </h:body>
</html>